<template>
  <div class="index-detail-box">
    <div class="index-detail-header">
      <navbar
        :title="title"
        :leftArrow="true"
        :onClickLeft="onClickLeft"
      ></navbar>
    </div>
    <div id="map">
      <mapgl></mapgl>
    </div>
  </div>
</template>

<script>
import navbar from "@/components/navbar/index.vue";
import mapgl from './map'
import { Toast } from 'vant';
export default {
  components: {
    navbar,
    mapgl
  },
  data() {
    return {
      title: this.$route.meta?.title,
    };
  },
  methods: {
    onClickLeft: function () {
      // this.$router.back();
      uni.navigateBack()
    },
  },
  mounted () {
    console.log(uni,'uni',process.env)
    Toast.fail('www');
    if (window.frames.length != parent.frames.length) {
      console.log('在iframe中111');
    } else {
      console.log('bu在iframe');
    }
  }
};
</script>

<style lang="scss">
.index-detail-box {
  display: flex;
  flex-direction: column;
  height: 100%;
  position: absolute;
  width: 100%;
  box-sizing: border-box;
  #map {
    flex: 1;
  }
}
</style>